/**
 *
 */
package com.yishuki.bluewhale.db.entity;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;

/**
 * @author yhzhu
 *
 */
@Entity
@Table(name="TBL_PERMISSION")
public class Permission implements Serializable {

	/**
	 *
	 */
	private static final long serialVersionUID = 6146417195459159868L;

	//PERMISSION_ID
	@Id
    @GeneratedValue(strategy = GenerationType.AUTO)
    @Column(name="PERMISSION_ID")
	private Long permissionId;

	@Column(name="NAME", unique=true, nullable=false, length=64)
	private String name;

	@Column(name="PERMISSION_MASK", unique=false, nullable=false)
	private Integer permissionMask;

	@Column(name="DESCRIPTION", unique=false, nullable=true, length=64)
	private String description;
	
	public Long getPermissionId() {
		return permissionId;
	}

	public void setPermissionId(Long permissionId) {
		this.permissionId = permissionId;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getDescription() {
		return description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	public Integer getPermissionMask() {
		return permissionMask;
	}

	public void setPermissionMask(Integer permissionMask) {
		this.permissionMask = permissionMask;
	}

	@Override
	public String toString() {
		return "Permission [permissionId=" + permissionId + ", name=" + name
				+ ", permissionMask=" + permissionMask + ", description="
				+ description + "]";
	}

}
